AC_INIT(linpvr, 0.0.1)
AM_INIT_AUTOMAKE

AC_PROG_CC

# Check for theora
# ----------------------------------------------------------------------------
PKG_CHECK_MODULES(THEORA, theora >= 1.0)
AC_SUBST([THEORA_LIBS])
CFLAGS="$CFLAGS $THEORA_CFLAGS"

# Check for ogg
# ----------------------------------------------------------------------------
PKG_CHECK_MODULES(OGG, ogg >= 1.1.3)
AC_SUBST([OGG_LIBS])
CFLAGS="$CFLAGS $OGG_CFLAGS"

# Check for gtk 
# ----------------------------------------------------------------------------
PKG_CHECK_MODULES(GTK2, gtk+-2.0 >= 2.8.0)
AC_SUBST([GTK2_LIBS])
CFLAGS="$CFLAGS $GTK2_CFLAGS"

# Check for libglade 
# ----------------------------------------------------------------------------
PKG_CHECK_MODULES(LIBGLADE2, libglade-2.0 >= 2.5.1)
AC_SUBST([LIBGLADE2_LIBS])
CFLAGS="$CFLAGS $LIBGLADE2_CFLAGS"

# Check for gthread
# ----------------------------------------------------------------------------
PKG_CHECK_MODULES(GTHREAD, gthread-2.0 >= 2.10.3)
AC_SUBST([GTHREAD_LIBS])
CFLAGS="$CFLAGS $GTHREAD_CFLAGS"

# Check for alsa
# ----------------------------------------------------------------------------
PKG_CHECK_MODULES(ALSA, alsa >= 1.0.11rc2)
AC_SUBST([ALSA_LIBS])
CFLAGS="$CFLAGS $ALSA_CFLAGS"

AC_OUTPUT([Makefile src/Makefile pixmaps/Makefile])
